Skip to content

fix: resolve golangci-lint failures blocking CI#21

Merged
dev-dami merged 2 commits intomainfrom
copilot/fix-ci-cd-issue
Mar 23, 2026
Merged

fix: resolve golangci-lint failures blocking CI#21
dev-dami merged 2 commits intomainfrom
copilot/fix-ci-cd-issue

Conversation

Copy link
Contributor

Copilot AI commented Mar 22, 2026

Three lint violations in test files were causing the CI Lint job to fail on every push to main.

Fixes

  • errorlint (module_test.go:894): Replace direct type assertion err.(*ParseError) with errors.As — direct assertions break on wrapped errors
  • errcheck (module_test.go:1032): Handle the ignored error return from filepath.Abs
  • staticcheck SA9003 (cgen_test.go:2380): Remove empty if !checker.Check(program) branch; call directly
// before
if _, ok := err.(*ParseError); !ok { ... }
absDir, _ := filepath.Abs(tmpDir)
if !checker.Check(program) { /* comment */ }

// after
var parseErr *ParseError
if !errors.As(err, &parseErr) { ... }
absDir, err := filepath.Abs(tmpDir)
if err != nil { t.Fatalf(...) }
checker.Check(program)
Original prompt

Fix ci/cd issue


📱 Kick off Copilot coding agent tasks wherever you are with GitHub Mobile, available on iOS and Android.

Copilot AI changed the title [WIP] Fix CI/CD issue fix: resolve golangci-lint failures blocking CI Mar 22, 2026
Copilot AI requested a review from dev-dami March 22, 2026 23:26
@dev-dami dev-dami marked this pull request as ready for review March 22, 2026 23:48
@dev-dami dev-dami merged commit a888818 into main Mar 23, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants